package com.lbd.service;

import com.lbd.util.ZipUtils;
import org.apache.tools.zip.ZipEntry;
import org.apache.tools.zip.ZipOutputStream;
import org.apache.tools.zip.ZipUtil;
import org.junit.Test;

import java.io.*;

/**
 * Created by WangYajie on 2016/11/3.
 */
public class TsetZipStream {
    @Test
    public void test() throws Exception {
        OutputStream out = new FileOutputStream("d:\\123.zip");
        ZipUtils.compress(out, new String[]{"E:\\temp\\1.jpg", "E:\\temp\\2.jpg", "E:\\temp\\3.jpg"});

    }

}
